package com.jie.demo.base;

import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.Verifier;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertThat;
import static org.junit.experimental.results.PrintableResult.testResult;
import static org.junit.experimental.results.ResultMatchers.isSuccessful;

public class Baseverifier {

    String sequence = "";

    @Rule
    public Verifier collector = new Verifier() {
        @Override
        protected void verify() {
            System.out.println("this is verify...");
            assertEquals("test verify ", sequence);
        }
    };

    @Test
    public void test01() {
        System.out.println("this is testing 01...");
        sequence += "test ";
    }

    @Test
    public void test02() {
        System.out.println("this is testing 02...");
        sequence = "test verify ";

    }
}
